<template>
	<view class="box">
		<view class="title">
			{{i18n.news}}
		</view>
		<navigator class="item white f13 fsf" :url="'./newsdetail?id='+item.id+'&title='+item.title+'&time='+item.createDate" v-for="(item,index) in list" :key="item.noticeId">
			<view class="left fcsf">
				<view class="content">
					{{item.title}}
				</view>
				<view class="time f12 color-gray mt5">
				{{item.createDate}}
				</view>
			</view>
			<view class="right ">
				<image :src="item.image" class="bor5"></image>
			</view>
		</navigator>
	</view>
	
</template>

<script>
	export default{
		data(){
			return{
				list:[],
			}
		},
		computed:{
			i18n() {
				return this.$t('tabber');
			}
		},
		onLoad() {
		},
		onShow() {
			uni.setTabBarItem({ index: 0, text: this.$t('tabber.home') })
			uni.setTabBarItem({ index: 1, text: this.$t('tabber.news') })
			uni.setTabBarItem({ index: 2, text: this.$t('tabber.assets') })
			uni.setTabBarItem({ index: 3, text: this.$t('tabber.user') })
			this.$http.post('news.getNewList').then(res=>{
				this.list=res.data.records
				
			})
		}
	}
</script>

<style lang="less">
	.box{
		padding: 0 30rpx;
		.title{
			margin-top: 60rpx;
			font-size:38rpx;
			font-family: STSongti, STSongti-Bold;
			font-weight: 600;
			text-align: center;
			letter-spacing: 4rpx;
			color: #fff;
		}
		.item{
			margin-top: 40rpx;
			.content{
				padding-right: 44rpx;
				line-height: 1.75;
			}
			image{
				width: 240rpx;
				height: 150rpx;
			}
		}
	}

</style>
